import request from "@/utils/request.js"

const API = {
    COMPANYLIST_URL: '/api/company/list',//获取公司结构列表
    USERLIST_URL: '/api/user/list',//获取员工列表
    COMPANYEDIT_URL: '/api/company/edit',//创建/编辑公司
    DEPARTMENTEDIT_URL: '/api/depart/edit',//创建/编辑部门
    DEPARTDEL_URL:'/api/depart/del',//删除部门
    USERIMPORT_URL: '/api/user/import',//excel人员批量导入
}
export const getCompanyList = values => request.post(API.COMPANYLIST_URL, values);
export const requireUserList = values => request.post(API.USERLIST_URL, values);
export const companyCreateEdit = values => request.post(API.COMPANYEDIT_URL, values);
export const departmentEdit = values => request.post(API.DEPARTMENTEDIT_URL, values);
export const departDel = values => request.post(API.DEPARTDEL_URL, values);
export const userImport = values => request.post(API.USERIMPORT_URL, values, {headers:{'Content-Type': 'multipart/form-data'}});
